package com.zhongwang.mms.gen.entity;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

public class BReportPlanAddLogExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public BReportPlanAddLogExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andCalIdIsNull() {
            addCriterion("cal_id is null");
            return (Criteria) this;
        }

        public Criteria andCalIdIsNotNull() {
            addCriterion("cal_id is not null");
            return (Criteria) this;
        }

        public Criteria andCalIdEqualTo(Integer value) {
            addCriterion("cal_id =", value, "calId");
            return (Criteria) this;
        }

        public Criteria andCalIdNotEqualTo(Integer value) {
            addCriterion("cal_id <>", value, "calId");
            return (Criteria) this;
        }

        public Criteria andCalIdGreaterThan(Integer value) {
            addCriterion("cal_id >", value, "calId");
            return (Criteria) this;
        }

        public Criteria andCalIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("cal_id >=", value, "calId");
            return (Criteria) this;
        }

        public Criteria andCalIdLessThan(Integer value) {
            addCriterion("cal_id <", value, "calId");
            return (Criteria) this;
        }

        public Criteria andCalIdLessThanOrEqualTo(Integer value) {
            addCriterion("cal_id <=", value, "calId");
            return (Criteria) this;
        }

        public Criteria andCalIdIn(List<Integer> values) {
            addCriterion("cal_id in", values, "calId");
            return (Criteria) this;
        }

        public Criteria andCalIdNotIn(List<Integer> values) {
            addCriterion("cal_id not in", values, "calId");
            return (Criteria) this;
        }

        public Criteria andCalIdBetween(Integer value1, Integer value2) {
            addCriterion("cal_id between", value1, value2, "calId");
            return (Criteria) this;
        }

        public Criteria andCalIdNotBetween(Integer value1, Integer value2) {
            addCriterion("cal_id not between", value1, value2, "calId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdIsNull() {
            addCriterion("cal_rpp_id is null");
            return (Criteria) this;
        }

        public Criteria andCalRppIdIsNotNull() {
            addCriterion("cal_rpp_id is not null");
            return (Criteria) this;
        }

        public Criteria andCalRppIdEqualTo(Integer value) {
            addCriterion("cal_rpp_id =", value, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdNotEqualTo(Integer value) {
            addCriterion("cal_rpp_id <>", value, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdGreaterThan(Integer value) {
            addCriterion("cal_rpp_id >", value, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("cal_rpp_id >=", value, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdLessThan(Integer value) {
            addCriterion("cal_rpp_id <", value, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdLessThanOrEqualTo(Integer value) {
            addCriterion("cal_rpp_id <=", value, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdIn(List<Integer> values) {
            addCriterion("cal_rpp_id in", values, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdNotIn(List<Integer> values) {
            addCriterion("cal_rpp_id not in", values, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdBetween(Integer value1, Integer value2) {
            addCriterion("cal_rpp_id between", value1, value2, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalRppIdNotBetween(Integer value1, Integer value2) {
            addCriterion("cal_rpp_id not between", value1, value2, "calRppId");
            return (Criteria) this;
        }

        public Criteria andCalDateIsNull() {
            addCriterion("cal_date is null");
            return (Criteria) this;
        }

        public Criteria andCalDateIsNotNull() {
            addCriterion("cal_date is not null");
            return (Criteria) this;
        }

        public Criteria andCalDateEqualTo(Date value) {
            addCriterion("cal_date =", value, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalDateNotEqualTo(Date value) {
            addCriterion("cal_date <>", value, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalDateGreaterThan(Date value) {
            addCriterion("cal_date >", value, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalDateGreaterThanOrEqualTo(Date value) {
            addCriterion("cal_date >=", value, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalDateLessThan(Date value) {
            addCriterion("cal_date <", value, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalDateLessThanOrEqualTo(Date value) {
            addCriterion("cal_date <=", value, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalDateIn(List<Date> values) {
            addCriterion("cal_date in", values, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalDateNotIn(List<Date> values) {
            addCriterion("cal_date not in", values, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalDateBetween(Date value1, Date value2) {
            addCriterion("cal_date between", value1, value2, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalDateNotBetween(Date value1, Date value2) {
            addCriterion("cal_date not between", value1, value2, "calDate");
            return (Criteria) this;
        }

        public Criteria andCalUidIsNull() {
            addCriterion("cal_uid is null");
            return (Criteria) this;
        }

        public Criteria andCalUidIsNotNull() {
            addCriterion("cal_uid is not null");
            return (Criteria) this;
        }

        public Criteria andCalUidEqualTo(Integer value) {
            addCriterion("cal_uid =", value, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalUidNotEqualTo(Integer value) {
            addCriterion("cal_uid <>", value, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalUidGreaterThan(Integer value) {
            addCriterion("cal_uid >", value, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalUidGreaterThanOrEqualTo(Integer value) {
            addCriterion("cal_uid >=", value, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalUidLessThan(Integer value) {
            addCriterion("cal_uid <", value, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalUidLessThanOrEqualTo(Integer value) {
            addCriterion("cal_uid <=", value, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalUidIn(List<Integer> values) {
            addCriterion("cal_uid in", values, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalUidNotIn(List<Integer> values) {
            addCriterion("cal_uid not in", values, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalUidBetween(Integer value1, Integer value2) {
            addCriterion("cal_uid between", value1, value2, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalUidNotBetween(Integer value1, Integer value2) {
            addCriterion("cal_uid not between", value1, value2, "calUid");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsIsNull() {
            addCriterion("cal_sup_reasons is null");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsIsNotNull() {
            addCriterion("cal_sup_reasons is not null");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsEqualTo(String value) {
            addCriterion("cal_sup_reasons =", value, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsNotEqualTo(String value) {
            addCriterion("cal_sup_reasons <>", value, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsGreaterThan(String value) {
            addCriterion("cal_sup_reasons >", value, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsGreaterThanOrEqualTo(String value) {
            addCriterion("cal_sup_reasons >=", value, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsLessThan(String value) {
            addCriterion("cal_sup_reasons <", value, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsLessThanOrEqualTo(String value) {
            addCriterion("cal_sup_reasons <=", value, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsLike(String value) {
            addCriterion("cal_sup_reasons like", value, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsNotLike(String value) {
            addCriterion("cal_sup_reasons not like", value, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsIn(List<String> values) {
            addCriterion("cal_sup_reasons in", values, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsNotIn(List<String> values) {
            addCriterion("cal_sup_reasons not in", values, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsBetween(String value1, String value2) {
            addCriterion("cal_sup_reasons between", value1, value2, "calSupReasons");
            return (Criteria) this;
        }

        public Criteria andCalSupReasonsNotBetween(String value1, String value2) {
            addCriterion("cal_sup_reasons not between", value1, value2, "calSupReasons");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}